		</div>
	</div>
<div class="sidebar">
      <div class="gadget">
       <%if (request.getUserPrincipal()!=null) {%>
        <div class="search">
          <h4>Search course by name:</h4>
          <form method="get" id="search" action="/salonmorandsmigi/CourseServlet">
            <span>
            <input type="text" name="name" id="s" />
            <input name="searchsubmit" type="image" src="/salonmorandsmigi/images/search.gif" value="Go" id="searchsubmit" class="btn"  />
            <input type="hidden" name="action" value="search">
            </span>
          </form>
          <div class="clr"></div>
        </div>
        <% }%>
      </div>
      <div class="gadget">
        <h2 class="star"><span>Sidebar</span> Menu</h2>
        <div class="clr"></div>
        <ul class="sb_menu">
          <li><a href="/salonmorandsmigi/index.jsp">Home</a></li>
          <% if (request.isUserInRole("admin")) {%>
          	<li><a href="/salonmorandsmigi/userinfo.jsp">User info</a></li>
          	<li><a href="/salonmorandsmigi/findcourse.jsp">Find Course</a></li>
          	<li><a href="/salonmorandsmigi/courses.jsp">Browse All Courses</a></li>
          	<li><a href="/salonmorandsmigi/admin/addcourse.jsp">Add course</a></li>
          	<li><a href="/salonmorandsmigi/admin/view.jsp">View Students</a></li>
          <%} 
          if (request.isUserInRole("student")){ %>
          	<li><a href="/salonmorandsmigi/userinfo.jsp">User info</a></li>
          	<li><a href="/salonmorandsmigi/findcourse.jsp">Find Course</a></li>
          	<li><a href="/salonmorandsmigi/courses.jsp">Browse All Courses</a></li>
          	<li><a href="/salonmorandsmigi/mycourses.jsp">Show Available courses</a>
          	<li><a href="/salonmorandsmigi/student/mycourses.jsp">My courses</a>
          	<li><a href="/salonmorandsmigi/student/timeline.jsp">View Time Table</a>
          <%} %>
          
        </ul>
      </div>
    </div>
    <div class="clr"></div>
  </div>